package com.yuntsg.ruiijn.paperana.test.small;

import cn.hutool.core.io.FileUtil;
import cn.hutool.crypto.SecureUtil;
import lombok.SneakyThrows;

import java.io.File;
import java.util.HashSet;
import java.util.Set;

public class PDF拆分校验md5 {
    @SneakyThrows
    public static void main(String[] args) {

//        String parentPath = "E:\\pdfpath\\";
        String parentPath = "M:\\xl\\";
        File[] ls = FileUtil.ls(parentPath);
        Set<String> strings = new HashSet<>();
        for (File l : ls) {
            String md5 = "";
            md5 = SecureUtil.md5(l);
            strings.add(md5);
            System.out.println(l.getName() + "++++" + md5);
        }

        System.out.println(strings.size());
        System.out.println(ls.length);
    }
}
